<template>
	<view class="set_data">
		<view class="set_data_item1">
			<text>商户名称</text>
			<text>{{store.name}}</text>
		</view>

		<view class="set_data_item2">
			<text>手机号</text>
			<text>{{userInfo.mobile}}</text>
		</view>

		<view class="set_data_item3">
			<text>商户身份</text>
			<text>{{homeModel.role_name}}</text>
		</view>
	</view>
</template>

<script>
	import ajax from '@/api/api.js'
	import url from '@/api/url.js'
	export default {
		data() {
			return {
				list: {
					title: "河南路易网路科技有限公司",
					title1: "15698542315 ",
					title2: "加油员",
				},
				userInfo: {},
				store: {},
				homeModel: {},


			}
		},
		methods: {
			// 获取用户信息
			getUseInfo() {
				this.$londing();
				ajax(url.userInfo, {

				}).then(res => {
					console.log(res)
					this.userInfo = res.data.data
					console.log(this.userInfo)
					this.store = this.userInfo.store
				}).catch(err => {
					console.log(err)

				})
			},

			getMerchantManage() {
				this.$londing()
				ajax(url.storeManagement, {
					data: {
						type: 1,
						time_type: 1,
					}
				}).then(res => {
					console.log(res)
					this.homeModel = res.data.data
				})
			}

		},
		onLoad() {
			this.getUseInfo()
			this.getMerchantManage()
		}
	}
</script>

<style lang="scss">
	.set_data {
		.set_data_item1 {
			padding: 10rpx 30rpx;
			background: white;
			line-height: 54px;
			display: flex;
			justify-content: space-between;
			border-bottom: 1px solid #eee;

			text:nth-child(1) {
				color: #666666;
				font-size: 15px;
			}

			text:nth-child(2) {
				color: #333333;
				font-size: 15px;
			}
		}

		.set_data_item2 {
			padding: 10rpx 30rpx;
			background: white;
			line-height: 54px;
			display: flex;
			justify-content: space-between;
			border-bottom: 1px solid #eee;

			text:nth-child(1) {
				color: #666666;
				font-size: 15px;
			}

			text:nth-child(2) {
				color: #333333;
				font-size: 15px;
			}
		}

		.set_data_item3 {
			padding: 10rpx 30rpx;
			background: white;
			line-height: 54px;
			display: flex;
			justify-content: space-between;
			border-bottom: 1px solid #eee;

			text:nth-child(1) {
				color: #666666;
				font-size: 15px;
			}

			text:nth-child(2) {
				color: #333333;
				font-size: 15px;
			}
		}

	}
</style>